package com.lw.sbdemo2.service;

import com.github.pagehelper.PageHelper;
import com.lw.sbdemo2.common.base.CrudService;
import com.lw.sbdemo2.common.vo.PageInfo;
import com.lw.sbdemo2.entity.TkOpinionCallback;
import com.lw.sbdemo2.mapper.TkOpinionCallbackMapper;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * <p>标题: 用户意见反馈表服务 - 业务逻辑层</p>
 * <p>描述: </p>
 * <p>版权: Copyright (c) 2019</p>
 * <p>公司: 山人行工作室</p>
 *
 * @version: 1.0
 * @author: LinWang
 * @date 2019-4-14
 */
@Slf4j
@Service
public class TkOpinionCallbackService extends CrudService<TkOpinionCallback, TkOpinionCallbackMapper> {

	/**
     * 获取用户分页列表
     *
     * @param query    搜索关键词
     * @param pageInfo 分页实体
	 * @param tkOpinionCallback 实体入参
     * @return 用户列表
     */
    public PageInfo<TkOpinionCallback> findListPage(String query, PageInfo pageInfo, TkOpinionCallback tkOpinionCallback) {
        PageHelper.startPage(pageInfo);
        List<TkOpinionCallback> tkOpinionCallbacklist = this.dao.findListPage(query, tkOpinionCallback);
        return new PageInfo<>(tkOpinionCallbacklist);
    }
}